package com.wangc.report.service.impl;

import com.wangc.report.dao.TaskLogMapper;
import com.wangc.report.entity.TaskLogEntity;
import com.wangc.report.service.TaskLogService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;

/**
 * Service实现类
 *
 * @author wangc
 * @email 1620415297@qq.com
 * @date 2020-10-20 14:13:58
 */
@Service("taskLogService")
public class TaskLogServiceImpl implements TaskLogService {
    @Resource
    private TaskLogMapper taskLogMapper;

    @Override
    public TaskLogEntity queryObject(Long id) {
        return taskLogMapper.selectByPrimaryKey(id);
    }

    @Override
    public List<TaskLogEntity> queryList(Map<String, Object> map) {
        return taskLogMapper.queryList(map);
    }

    @Override
    public int queryTotal(Map<String, Object> map) {
        return taskLogMapper.queryTotal(map);
    }

    @Override
    public int save(TaskLogEntity taskLog) {
        return taskLogMapper.insertSelective(taskLog);
    }

    @Override
    public int update(TaskLogEntity taskLog) {
        return taskLogMapper.updateByPrimaryKeySelective(taskLog);
    }

    @Override
    public int delete(Long id) {
        return taskLogMapper.deleteByPrimaryKey(id);
    }

    @Override
    public int deleteBatch(Long[] ids) {
        return taskLogMapper.deleteBatch(ids);
    }
}
